﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Project_Detail.aspx.cs" Inherits="EcSalseManage.EcSalse.Salse_Detail" EnableEventValidation="false" %>

<%@ Register Assembly="MetaBuilders.WebControls" Namespace="MetaBuilders.WebControls"
    TagPrefix="mb" %>
<%@ Register Src="../PageCommon/Report_Tab.ascx" TagName="Report_Tab" TagPrefix="uc1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
    <title>项目销售管理系统-项目管理</title>
    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
    <meta http-equiv="imagetoolbar" content="no"/>
    <meta name="apple-mobile-web-app-capable" content="yes"/>
    <link href="../css/skin.css" type="text/css" rel="stylesheet">
    <link href="../css/SelectBox.css" type="text/css" rel="stylesheet">
     <link href="../css/autocomplete.css" type="text/css" rel="stylesheet">
    <script language="javascript" type="text/javascript" src="../js/My97DatePicker/WdatePicker.js"></script>
    <script language="javascript" type="text/javascript" src="../js/net.js"></script>
    <script language="javascript" type="text/javascript" src="../js/SelectBox.js"></script>
    <script type="text/javascript" language="javascript">

        function test() {
            if (document.all.ddlFileType.value == "") {
                alert("请选择附件类型！");
                return false;
            }
        }

        function getEmployee_Marketing2(Code, Employee) {
            document.getElementById("hfldMarketing2").value = Code;
            document.getElementById("txtMarketing2").value = Employee;
            
        }

        function getEmployee_Marketing1(Code, Employee) {
            document.getElementById("hfldMarketing1").value = Code;
            document.getElementById("txtMarketing1").value = Employee;
        }

        function getEmployee_Manager(Code, Employee) {
            document.getElementById("hfldManager").value = Code;
            document.getElementById("txtManager").value = Employee;
        }

        function getEmployee_Business(Code, Employee) {
            document.getElementById("hfldBusiness").value = Code;
            document.getElementById("txtBusiness").value = Employee;
        }

        function getEmployee_DepartmentHead(Code, Employee) {
            document.getElementById("hfldDepartmentHead").value = Code;
            document.getElementById("txtDepartmentHead").value = Employee;
        }
        
        

        function addRow() {
            var FilePath = document.getElementById("txtFilePath");
            
            if (FilePath.value == "") {
                alert("请选择上传文件");
                return false;
            }
            var filetype = document.getElementById("ddlFileType");
            if (filetype.value == "") {
                alert("请选择附件类型");
                return false;
            }

            var objMyTable = document.getElementById("tempTable");
            objMyTable.style.display = "block";
            var index = objMyTable.rows.length;
            var nextRow = objMyTable.insertRow(index);
            nextRow.setAttribute("style", "background-color:rgb(248, 244, 228)");

            var newCellCartonNo1 = nextRow.insertCell();
            var obj = document.getElementById("ddlFileType");
            var n = obj.selectedIndex;
            newCellCartonNo1.innerHTML = obj.options[n].text;

            document.getElementById("HiddenField2").value += "" + obj.options[n].value + "," + document.getElementById("txtFilePath").value + "," + document.getElementById("txtProjectDesc").value + "|";

            var newCellCartonNo4 = nextRow.insertCell();
            newCellCartonNo4.innerHTML = "<input style='border-width: 0px; border-style: dotted;'  onclick='deleteRow(" + index + ")'   src='../images/delete.gif' type='image'>";
            filetype.value = "";
        }

        function deleteRow(obj) {

            var temp = document.getElementById("HiddenField2").value;

            temp = temp.substring(0, temp.length - 1);

            var arrayObj = temp.split("|");
            arrayObj.splice(obj - 1, 1);
            temp = "";
            for (i = 0; i < arrayObj.length; i++) {
                temp += arrayObj[i] + "|";
            }
            document.getElementById("HiddenField2").value = temp;

            document.getElementById("tempTable").deleteRow(obj);
        }

        String.prototype.Trim = function() {
            return this.replace(/(^\s*)|(\s*$)/g, "");
        }
        String.prototype.IsNullOrEmpty = function() {
            if (this.Trim() == null || this.Trim() == "") {
                return true;
            }
            return false;
        }

        function changeProjectState(oElem) {
            var strValue = oElem.options[oElem.selectedIndex].value;
            if (strValue == "2")
                document.getElementById("txtUserInput").setAttribute("disabled", "disabled");
            else
                document.getElementById("txtUserInput").removeAttribute("disabled");
        }
    
        window.onload = function() {
            var elemSpan = document.createElement("span");
            elemSpan.id = "spanOutput";
            elemSpan.className = "spanTextDropdown";
            document.body.appendChild(elemSpan);
            //Listing 10.7
            document.form1.txtUserInput.obj =
          SetProperties(document.form1.txtUserInput,
            document.form1.txtUserValue, '../PageCommon/DepartmentSearch.aspx',
            true, true, true, true, "没有找到数据", false, null);
        }
        function showHrKD(oElem) {
            var strValue = oElem.options[oElem.selectedIndex].value;
            var arrayObj = strValue.split(',');
            if (arrayObj.length > 1) {
                document.getElementById("txtUserInput").value = arrayObj[1];
            } else {
                document.getElementById("txtUserInput").value = "";
            }
        }

        function FillCity(oElem, oTarget) {
            var strValue = oElem.options[oElem.selectedIndex].value;
            var url = '../PageCommon/ProjectCitySearch.aspx';
            var strParams = 'q=' + strValue + "&f=" + oTarget.form.name + "&e=" + oTarget.name;
            var loader1 = new net.ContentLoader(url, FillDropDown, null, "POST", strParams);
        }

        function FillDistrict(oElem, oTarget) {
            var strValue = oElem.options[oElem.selectedIndex].value;
            if (strValue == "3") {
                var url = '../PageCommon/ProjectDistrictSearch.aspx';
                var strParams = 'q=' + strValue + "&f=" + oTarget.form.name + "&e=" + oTarget.name;
                var loader1 = new net.ContentLoader(url, FillDropDown, null, "POST", strParams);
            } else if (strValue == "10" || strValue == "11" || strValue == "12" || strValue == "13" || strValue == "14" || strValue == "15") {
                var url = '../PageCommon/ProjectDistrictTypeSearch.aspx';
                var strParams = 'q=' + strValue + "&f=" + oTarget.form.name + "&e=" + "ddlDistrictType";
                var loader1 = new net.ContentLoader(url, FillDropDown, null, "POST", strParams);
            }
        }


        function FillDistrictType(oElem, oTarget) {
            var strValue = oElem.options[oElem.selectedIndex].value;
            var url = '../PageCommon/ProjectDistrictTypeSearch.aspx';
            var strParams = 'q=' + strValue + "&f=" + oTarget.form.name + "&e=" + oTarget.name;
            var loader1 = new net.ContentLoader(url, FillDropDown, null, "POST", strParams);
        }

        function FillDropDown() {
            var xmlDoc = this.req.responseXML.documentElement;

            var xSel = xmlDoc.
           getElementsByTagName('selectElement')[0];
            var strFName = xSel.
           childNodes[0].firstChild.nodeValue;
            var strEName = xSel.
           childNodes[1].firstChild.nodeValue;

            var objDDL = document.forms[strFName].
           elements[strEName];
            objDDL.options.length = 0;

            var xRows = xmlDoc.
          getElementsByTagName('entry');
            for (i = 0; i < xRows.length; i++) {
                var theText = xRows[i].
              childNodes[0].firstChild.nodeValue;
                var theValue = xRows[i].
              childNodes[1].firstChild.nodeValue;
                var option = new Option(theText,
                            theValue);
                objDDL.options.add(option,
                          objDDL.options.length);
            }
        }

        function AddCommission() {
            var div = document.createElement("div");
            div.innerHTML = "以结算条件作为选项的<input name='Commission1' type='text'  style='width:40px;'  /><select name='Commission2'><option value='0'>天</option><option value='1'>工作天</option></select>内,支付<input name='Commission3' style='width:40px;' type='text' />%；<input id='Button2' type='button' value='删除' onclick='DelArea(\"CommissionArea\",this.parentNode)' />";
            document.getElementById("CommissionArea").appendChild(div);
        }

        var d = 1;
        function AddInputArea_UnionDeveloper() {
            var str = "";
            if (document.getElementById("radlUnionDeveloper_0").checked)
                str = " 金额";
            else if (document.getElementById("radlUnionDeveloper_1").checked)
                str = " 套数";
            else if (document.getElementById("radlUnionDeveloper_2").checked)
                str = " 面积";
            else {
                alert("请先选择类型");
                return false;
            }
            var div = document.createElement("div");
            div.setAttribute("id", "tc" + n);
            div.innerHTML = d + "." + str + "<input type='text' name='inputUnionDeveloper1'  class='edline' style='width:50px;' />以上，按<input type='text' class='edline' style='width:50px;' name='inputUnionDeveloper2' />%计提 <input type='button' value='删除' onclick='DelArea(\"UnionDeveloperArea\",this.parentNode)'/>";
            document.getElementById("UnionDeveloperArea").appendChild(div);
            d++;
        }
        var u = 1;
        function AddInputArea_UnionComm() {
            var str = "";
            if (document.getElementById("radlUnionComm_0").checked)
                str = " 金额";
            else if (document.getElementById("radlUnionComm_1").checked)
                str = " 套数";
            else if (document.getElementById("radlUnionComm_2").checked)
                str = " 面积";
            else {
                alert("请先选择类型");
                return false;
            }
            var div = document.createElement("div");
            div.setAttribute("id", "tc" + n);
            div.innerHTML = u + "." + str + "<input type='text' name='inputUnionComm1'  class='edline' style='width:50px;' />以上，按<input type='text' class='edline' style='width:50px;' name='inputUnionComm2' />%计提 <input type='button' value='删除' onclick='DelArea(\"UnionCommArea\",this.parentNode)'/>";
            document.getElementById("UnionCommArea").appendChild(div);
            u++;
        }

        var l = 1;
        function AddInputArea_Lease() {
            var str = "";
            if (document.getElementById("radlLease_0").checked)
                str = " 招赁套数";
            else if (document.getElementById("radlLease_1").checked)
                str = " 面积";
            else if (document.getElementById("radlLease_2").checked)
                str = " 货量";
            else if (document.getElementById("radlLease_3").checked)
                str = " 月均租金";
            else {
                alert("请先选择类型");
                return false;
            }
            var div = document.createElement("div");
            div.setAttribute("id", "tc" + n);
            div.innerHTML = l + "." + str + "<input type='text' name='inputLease1'  class='edline' style='width:50px;' />以上，按<input type='text' class='edline' style='width:50px;' name='inputLease2' />%计提 <input type='button' value='删除' onclick='DelArea(\"LeaseArea\",this.parentNode)'/>";
            document.getElementById("LeaseArea").appendChild(div);
            l++;
        }

        var s = 1;
        function AddInputArea_SalseAgency() {
            var str = "";
            if (document.getElementById("radlSalseAgency_0").checked)
                str = " 金额";
            else if (document.getElementById("radlSalseAgency_1").checked)
                str = " 套数";
            else if (document.getElementById("radlSalseAgency_2").checked)
                str = " 面积";
            else {
                alert("请先选择类型");
                return false;
            }
            var div = document.createElement("div");
            div.setAttribute("id", "tc" + n);
            div.innerHTML = s + "." + str + "<input type='text' name='inputSalseAgency1'  class='edline' style='width:50px;' />以上，按<input type='text' class='edline' style='width:50px;' name='inputSalseAgency2' />%计提 <input type='button' value='删除' onclick='DelArea(\"SalseAgencyArea\",this.parentNode)'/>";
            document.getElementById("SalseAgencyArea").appendChild(div);
            s++;
        }

        var n = 1;
        function AddInputArea() {
            var str = "";
            if (document.getElementById("radlEncourage_0").checked)
                str = " 金额";
            else if (document.getElementById("radlEncourage_1").checked)
                str = " 套数";
            else if (document.getElementById("radlEncourage_2").checked)
                str = " 面积";
            else {
                alert("请先选择类型");
                return false;
            }
            var div = document.createElement("div");
            div.setAttribute("id", "tc" + n);
            div.innerHTML = n + "." + str + "<input type='text' name='inputEncourage1'  class='edline' style='width:50px;' />以上，按<input type='text' class='edline' style='width:50px;' name='inputEncourage2' />%计提 <input type='button' value='删除' onclick='DelArea(\"EncourageArea\",this.parentNode)'/>";
            document.getElementById("EncourageArea").appendChild(div);
            n++;
        }

        function DelArea(area, obje) {
            document.getElementById(area).removeChild(obje);
            if (area == "EncourageArea")
                n--;
            else if (area == "SalseAgencyArea")
                s--;
            else if (area == "LeaseArea")
                l--;
            else if (area == "UnionCommArea")
                u--;
            else if (area == "UnionDeveloperArea")
                d--;
        }

        function DataCheck() {
            
            if (document.all("txtProjectName").value.IsNullOrEmpty()) {
                alert("请输入项目名称！");
                document.all['txtProjectName'].focus();
                return false;
            }
            if (document.all("txtDeveloper").value.IsNullOrEmpty()) {
                alert("请输入发展商名称！");
                document.all['txtDeveloper'].focus();
                return false;
            }
            if (document.all("ddlDepartment").value.IsNullOrEmpty()) {
                alert("请选择所属部门");
                document.all['ddlDepartment'].focus();
                return false;
            }
            if (document.all("txtSignDate").value.IsNullOrEmpty()) {
                alert("请选择合同签署日期");
                document.all['txtSignDate'].focus();
                return false;
            }
            if (document.all("ddlSignType").value.IsNullOrEmpty()) {
                alert("请选择合同签署类型");
                document.all['ddlSignType'].focus();
                return false;
            }
            if (document.all("ddlProjectState").value.IsNullOrEmpty()) {
                alert("请选择项目现况");
                document.all['ddlProjectState'].focus();
                return false;
            }
            
            if (document.all("ddlProjectState").value != "2") {
                if (document.all("lstHr").length <= 0) {
                    alert('请选择人事树！');
                    return false;
                }
            }
            
            if (document.getElementById("txtProject_AvailableArea").value == "" ) {
                alert("请输入可售面积");
                document.all['txtProject_AvailableArea'].focus();
                return false;
            }
            if (document.getElementById("txtProject_AvailableVolume").value == "") {
                alert("请输入可售货量");
                document.all['txtProject_AvailableVolume'].focus();
                return false;
            }
            if (document.all("ddlDeveloperProvince").value.length == 0
			    || document.all("ddlDeveloperCity").value.length == 0
			    || document.all("ddlDeveloperCity").value == "-1"
			    || document.all("ddlDeveloperDistrict").value == "-1"
			    || document.all("ddlDeveloperDistrict").value == ""
			    || document.all("txtDeveloperAddress").value.length == 0) {
                alert("请输入项目地址");
                document.all['ddlDeveloperProvince'].focus();
                return false;
            }

            if (document.all("txtDateStart").value.IsNullOrEmpty()) {
                alert("请选择代理期开始日期");
                document.all['txtDateStart'].focus();
                return false;
            }
            if (document.all("txtDateEnd").value.IsNullOrEmpty()) {
                alert("请选择代理期结束日期");
                document.all['txtDateEnd'].focus();
                return false;
            }

            var radlAccountCycle = document.all("radlAccountCycle");
            var i = 0;
            for (i = 0; i < radlAccountCycle.length; i++) {
                if (radlAccountCycle[i].checked == true) {
                    break;
                }
                if (i == radlAccountCycle.length - 1) {
                    alert("请选择结算周期");
                    return false;
                }
            }

            var radlSalseAccountCondition = document.all("radlSalseAccountCondition");
            var i = 0;
            for (i = 0; i < radlSalseAccountCondition.length; i++) {
                if (radlSalseAccountCondition[i].checked == true) {
                    break;
                }
                if (i == radlSalseAccountCondition.length - 1) {
                    alert("请选择结算条件");
                    return false;
                }
            }

            var radlOutComm = document.all("radlOutComm");
            for (i = 0; i < radlOutComm.length; i++) {
                if (radlOutComm[i].checked == true)
                    break;
                if (i == radlOutComm.length - 1) {
                    alert("请选择对外分佣");
                    return false;
                }
            }
            
            var radlReferral = document.all("radlReferral");
            for (i = 0; i < radlReferral.length; i++) {
                if (radlReferral[i].checked == true) {
                    break;
                }
                if (i == radlReferral.length - 1) {
                    alert("请选择转介盘源转介费");
                    return false;
                }
            }
            
            

            GetAddInput();

            if (document.all.ddlFileType.value == "") {
                alert("请选择附件类型！");
                return false;
            }
            if (document.getElementById("txtFilePath").value == "") {
                alert("项目附件不能为空！");
                return false;
            }
            

        }

        function GetAddInput() {
            var Commission1 = document.getElementsByName("Commission1");
            var Commission2 = document.getElementsByName("Commission2");
            var Commission3 = document.getElementsByName("Commission3");
            for (var i = 0; i < Commission1.length; i++) {
                if (Commission1[i].value.IsNullOrEmpty() || Commission3[i].value.IsNullOrEmpty()) {
                    alert("收佣条件内容不能为空");
                    return false;
                }
                document.getElementById("hfldCommission").value += Commission1[i].value + "," + Commission3[i].value + "," + Commission2[i].value + "|";
            }


            var names = document.getElementsByName("inputEncourage1");
            var genders = document.getElementsByName("inputEncourage2");

            for (var i = 0; i < names.length; i++) {
                if (names[i].value.IsNullOrEmpty() || genders[i].value.IsNullOrEmpty()) {
                    alert("额外奖励条款内容不能为空！");
                    return false;
                }
                document.getElementById("hfldEncourage").value += names[i].value + "," + genders[i].value + "|";
            }


            var objSignType = document.getElementById("ddlSignType");
            var index = objSignType.selectedIndex;

            var list = document.getElementById("chklAgencyType").getElementsByTagName("input");

            if (list[1].checked == true) {
                names = document.getElementsByName("inputSalseAgency1");
                genders = document.getElementsByName("inputSalseAgency2");
                for (var i = 0; i < names.length; i++) {
                    if (names[i].value.IsNullOrEmpty() || genders[i].value.IsNullOrEmpty()) {
                        alert("销售代理条款内容不能为空！");
                        return false;
                    }
                    document.getElementById("hfldSalseAgency").value += names[i].value + "," + genders[i].value + "|";
                }
                if (document.getElementById("hfldSalseAgency").value == "") {
                    alert("销售代理条款不能为空！");
                    return false;
                }
            }


            if (list[2].checked == true) {
                names = document.getElementsByName("inputLease1");
                genders = document.getElementsByName("inputLease2");
                for (var i = 0; i < names.length; i++) {
                    if (names[i].value.IsNullOrEmpty() || genders[i].value.IsNullOrEmpty()) {
                        alert("招租中原成交条款内容不能为空！");
                        return false;
                    }
                    document.getElementById("hfldLease").value += names[i].value + "," + genders[i].value + "|";
                }
                if (document.getElementById("hfldLease").value == "") {
                    alert("招租中原成交条款不能为空！");
                    return false;
                }
            }

            if (list[3].checked == true || objSignType.options[index].text == "联动") {
                names = document.getElementsByName("inputUnionComm1");
                genders = document.getElementsByName("inputUnionComm2");
                for (var i = 0; i < names.length; i++) {
                    if (names[i].value.IsNullOrEmpty() || genders[i].value.IsNullOrEmpty()) {
                        alert("联动成交，佣金条款内容不能为空！");
                        return false;
                    }
                    document.getElementById("hfldUnionComm").value += names[i].value + "," + genders[i].value + "|";
                }
                if (document.getElementById("hfldUnionComm").value == "") {
                    alert("联动成交，佣金条款不能为空！");
                    return false;
                }

                names = document.getElementsByName("inputUnionDeveloper1");
                genders = document.getElementsByName("inputUnionDeveloper2");
                for (var i = 0; i < names.length; i++) {
                    if (names[i].value.IsNullOrEmpty() || genders[i].value.IsNullOrEmpty()) {
                        alert("联动成交，发展商额外奖金内容不能为空！");
                        return false;
                    }
                    document.getElementById("hfldUnionDeveloper").value += names[i].value + "," + genders[i].value + "|";
                }
                if (document.getElementById("hfldUnionDeveloper").value == "") {
                    alert("联动成交，发展商额外奖金不能为空！");
                    return false;
                }
            }
        }


        function show(index) {

            if (index == 1) {
                document.getElementById("lk1").className = "asel";
                document.getElementById("pg1").style.display = "";

                document.getElementById("lk2").className = "aa";
                document.getElementById("pg2").style.display = "none";

                document.getElementById("lk3").className = "aa";
                document.getElementById("pg3").style.display = "none";

                document.getElementById("lk4").className = "aa";
                document.getElementById("pg4").style.display = "none";

                document.getElementById("lk5").className = "aa";
                document.getElementById("pg5").style.display = "none";

            }
            else if (index == 2) {
                document.getElementById("lk1").className = "aa";
                document.getElementById("pg1").style.display = "none";

                document.getElementById("lk2").className = "asel";
                document.getElementById("pg2").style.display = "";


                document.getElementById("lk3").className = "aa";
                document.getElementById("pg3").style.display = "none";

                document.getElementById("lk4").className = "aa";
                document.getElementById("pg4").style.display = "none";

                document.getElementById("lk5").className = "aa";
                document.getElementById("pg5").style.display = "none";
            } else if (index == 3) {
                document.getElementById("lk1").className = "aa";
                document.getElementById("pg1").style.display = "none";

                document.getElementById("lk2").className = "aa";
                document.getElementById("pg2").style.display = "none";

                document.getElementById("lk3").className = "asel";
                document.getElementById("pg3").style.display = "";

                document.getElementById("lk4").className = "aa";
                document.getElementById("pg4").style.display = "none";

                document.getElementById("lk5").className = "aa";
                document.getElementById("pg5").style.display = "none";

            } else if (index == 4) {
                document.getElementById("lk1").className = "aa";
                document.getElementById("pg1").style.display = "none";

                document.getElementById("lk2").className = "aa";
                document.getElementById("pg2").style.display = "none";

                document.getElementById("lk3").className = "aa";
                document.getElementById("pg3").style.display = "none";

                document.getElementById("lk4").className = "asel";
                document.getElementById("pg4").style.display = "";

                document.getElementById("lk5").className = "aa";
                document.getElementById("pg5").style.display = "none";

            } else if (index == 5) {

                document.getElementById("lk1").className = "aa";
                document.getElementById("pg1").style.display = "none";

                document.getElementById("lk2").className = "aa";
                document.getElementById("pg2").style.display = "none";

                document.getElementById("lk3").className = "aa";
                document.getElementById("pg3").style.display = "none";

                document.getElementById("lk4").className = "aa";
                document.getElementById("pg4").style.display = "none";

                document.getElementById("lk5").className = "asel";
                document.getElementById("pg5").style.display = "";
            }

        }


     </script>
 <style type="text/css">

  body{ font-size:12px; }

  .aa 
  {
  	 background-image: url(../images/u65_normal.png);
    width: 121px;
    text-align: center;
    height: 26;
    line-height: 26px;
    display: inline-block; 
  }

  .asel  
  {
  	background-image: url(../images/u59_normal.png);
    width: 121px;
    text-align: center;
    height: 26;
    line-height: 26px;
    display: inline-block;
    color:#FFFFFF; 
  }
     </style>

<!--[if IE 6]>
    <link href="Default_files/axurerp_pagespecificstyles_ie6.css" type="text/css" rel="stylesheet">
<![endif]-->

</head>
<body>
<form id="form1" runat="server">


<table width="100%" border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td width="17" valign="top" background="../images/mail_leftbg.gif"><img src="../images/left-top-right.gif" width="17" height="29" /></td>
    <td valign="top" background="../images/content-bg.gif">
                <uc1:Report_Tab ID="Report_Tab1" runat="server" Visible="False" />
     </td>
    <td width="16" valign="top" background="../images/mail_rightbg.gif"><img src="../images/nav-right-bg.gif" width="16" height="29" /></td>
  </tr>
  <tr>
    <td valign="middle" background="../images/mail_leftbg.gif">&nbsp;</td>
    <td valign="top" bgcolor="#F7F8F9">
    <table width="98%" border="0" align="center" cellpadding="0" cellspacing="0">
    
      <tr>
        <td colspan="4" valign="top">
        <!-- 内容区域-->
          
        <center>
        
         <table  style="line-height:34px">
         
            <tr style="line-height:normal;">
                 <td align="center" colspan="4" style="border-bottom:1px solid #cccccc;"><span id="Span1" style="font-size:28px;"><br> <asp:Label ID="lblTitle" runat="server"></asp:Label>
                     </span>
                     <br /><br /></td>
             </tr>
             <tr style="line-height:normal;">
                <td colspan="4">&nbsp;</td>
             </tr>
            <tr>
                <td ><span class="detailTitle">项目名称：</span></td>
                <td  align="left"><asp:TextBox ID="txtProjectName" runat="server" MaxLength="50" Style="text-align: center"
                                                                                            TabIndex="7" Width="200px"></asp:TextBox></td>
                <td colspan="2" valign="top">
                <span  class="detailTitle">人事树名称：</span>
                    <asp:TextBox ID="txtUserInput" runat="server"  Style="text-align: center; width:50px;" AutoCompleteType="Disabled" TabIndex="8"></asp:TextBox>
                    <asp:Button ID="btnAddHr" runat="server" Text="增加" onclick="btnAddHr_Click" />
                    <asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
    <ContentTemplate>
        <div style=" position:absolute; left:880px;top:140px;"> 
            <asp:ListBox ID="lstHr"  Width="140" runat="server"></asp:ListBox><br /> 
            <asp:Button ID="btnClear" runat="server" Text="清除一个" onclick="btnClear_Click" />
        </div>
    </ContentTemplate>
    <Triggers>
        <asp:AsyncPostBackTrigger ControlID="btnAddHr" EventName="Click" />
    </Triggers>
</asp:UpdatePanel>
                    <asp:HiddenField ID="HiddenField1" runat="server" />
                    <input type="hidden" name="txtUserValue"  id="hidden1" />    
                
                </td>
            </tr>   
            <tr>
                <td><span class="detailTitle">发展商名称：</span></td>
                <td align="left"><asp:TextBox ID="txtDeveloper" runat="server" MaxLength="50" Style="text-align: center"
                                                                                            TabIndex="7" Width="200"></asp:TextBox></td>
                <td ><span class="detailTitle">所属部门：</span></td>
                <td align="left">
                    <asp:DropDownList ID="ddlDepartment" runat="server" Width="200px" TabIndex="38"></asp:DropDownList>
               </td>
            </tr>
            <tr>
                <td><span class="detailTitle">合同签署日期：</span></td>
                <td align="left"><asp:TextBox ID="txtSignDate" runat="server" MaxLength="50" Style="text-align: center"
                                                                                            TabIndex="7" Width="200" class="Wdate" onclick="WdatePicker()"></asp:TextBox></td>
                <td ><span class="detailTitle">合同签署类型：</span></td>
                <td align="left"><asp:DropDownList ID="ddlSignType" runat="server" Width="200" TabIndex="38" >
                                                                                        </asp:DropDownList></td>
            </tr>
            <tr>
                <td><span class="detailTitle">项目现况：</span></td>
                <td align="left"><asp:DropDownList ID="ddlProjectState" runat="server" Width="200" TabIndex="38">
                                                                                        </asp:DropDownList></td>
                <td colspan="2">
                    可售面积&nbsp;&nbsp;<asp:TextBox ID="txtProject_AvailableArea" Width="50" runat="server"></asp:TextBox>&nbsp;&nbsp;&nbsp;&nbsp;可售货量&nbsp;&nbsp;
                    <asp:TextBox ID="txtProject_AvailableVolume" Width="50" runat="server"></asp:TextBox>
                 </td>
            
            </tr>
            <tr>
                <td><span class="detailTitle">项目地址：</span></td>
                <td align="left" colspan="3">
                <asp:DropDownList ID="ddlDeveloperProvince" runat="server" Width="73px" TabIndex="20"></asp:DropDownList>
                <asp:DropDownList ID="ddlDeveloperCity" runat="server" Width="73px" TabIndex="21"></asp:DropDownList>
                <asp:DropDownList ID="ddlDeveloperDistrict" runat="server" Width="73px" TabIndex="22"></asp:DropDownList>
                <asp:TextBox ID="txtDeveloperAddress" runat="server" Width="202px"></asp:TextBox>
                    &nbsp;&nbsp;&nbsp;&nbsp;
                <span class="detailTitle">区域属性：</span><asp:DropDownList ID="ddlDistrictType" runat="server" Width="73px" TabIndex="22"></asp:DropDownList>
                </td>
         
            </tr>
            <tr>
                <td><span class="detailTitle">产品类型：</span></td>
                <td align="left" colspan="3">
                    <asp:CheckBoxList ID="chklProductType" runat="server" 
                        RepeatDirection="Horizontal" class="detailTitle">
                    </asp:CheckBoxList>
                </td>
            </tr>
            <tr>
                <td><span class="detailTitle">代理期：</span></td>
                <td align="left" colspan="3">
                <table><tr><td>
                   <asp:TextBox ID="txtDateStart" runat="server" MaxLength="50" Style="text-align: center" TabIndex="7" Width="100" class="Wdate" onFocus="WdatePicker({maxDate:'#F{$dp.$D(\'txtDateEnd\')}'})"></asp:TextBox>
                    至
                    <asp:TextBox ID="txtDateEnd" runat="server" MaxLength="50" Style="text-align: center" TabIndex="7" Width="100" class="Wdate" onFocus="WdatePicker({minDate:'#F{$dp.$D(\'txtDateStart\')}'})"></asp:TextBox>
                    &nbsp;&nbsp;&nbsp;&nbsp;<span class="detailTitle">代理类型：</span> </td><td>
               <asp:CheckBoxList ID="chklAgencyType" runat="server" 
                        RepeatDirection="Horizontal" class="detailTitle"
                        >
                    </asp:CheckBoxList>
                   </td></tr></table>
                </td>
          
            </tr>
            <tr>
                <td valign="top"><span class="detailTitle">点数条件：</span></td>
                <td align="left" colspan="3">
                 <div style="margin-bottom:-6px;" id="daili">
                    <span id="lk2" onclick="show(2)" class="aa" style="display:none;">前期策划</span>
                    <span id="lk3" onclick="show(3)" class="aa" style="display:none;">销售代理</span>
                    <span id="lk4" onclick="show(4)" class="aa" style="display:none;">招租</span>
                    <span id="lk5" onclick="show(5)" class="aa" style="display:none;">联动</span>
                    <span id="lk1" onclick="show(1)" class="asel" style="display:inline-block;"> 额外奖励金条款</span>
                 </div>
                 </div>
                 <div id="pg1" class="page" style="" >
                     <div  style="position: relative;left: 20px;width: 150px;font-family: Arial;text-align: left;">
                        <div ><p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                            一.销售奖励：</span></p></div>
                     </div>
                     <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                        <table>
                            <tr>
                                <td>
                                    <asp:RadioButtonList ID="radlEncourage" runat="server" RepeatDirection="Horizontal">
                                    </asp:RadioButtonList>
                                </td>
                                <td>
                                <input type="button" value="增加" onclick="AddInputArea()" /> 
                                    <asp:HiddenField ID="hfldEncourage" runat="server" />
                                </td>
                            </tr>
                        </table>
                         <div id="EncourageArea"></div><asp:HiddenField ID="hfdlEncourage" runat="server" />
       
                     </div>
                     <div  style="position: relative;left: 20px;width: 150px;font-family: Arial;text-align: left;">
                        <div ><p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                            二.溢价奖励：</span></p></div>
                     </div>
                     <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                          <div ><p style="text-align:left; padding:0px;margin:0px;">
                              
                              <asp:TextBox ID="TextBox1" runat="server" TextMode="MultiLine" Height="35px" 
                                  Width="484px"></asp:TextBox>
                              
                              </p></div>
                     </div>
                 </div>
                 <div id="pg2" class="page" style="display:none;" >
                     <div  style="position: relative;left: 20px;width: 150px;font-family: Arial;text-align: left;">
                        
                        <div style="width: 507px;">
                        <p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                         前期策划费：<asp:TextBox ID="txtProject_EarlyPlot_Fees" runat="server"></asp:TextBox><br />
                            一.分阶段支付方式：</span></p>
                        </div>
                     </div>
                     <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                          <div >
                               <p style="text-align:left; padding:0px;margin:0px;">
                                    A.代理合同签署<asp:TextBox ID="txtQqchA1" runat="server"  Width="40" CssClass="edline"></asp:TextBox><asp:DropDownList ID="ddlQqchA" runat="server" Width="80">
                                        <asp:ListItem Value="1">天</asp:ListItem>
                                        <asp:ListItem Value="2">工作天内</asp:ListItem>
                                    </asp:DropDownList>
                                    支付策划费<asp:TextBox ID="txtQqchA2" runat="server"  Width="40"  CssClass="edline"></asp:TextBox>元。
                              </p>
                              <p style="text-align:left; padding:0px;margin:0px;">
                                    B.提交策划报告初稿<asp:TextBox ID="txtQqchB1" runat="server"  Width="40"  CssClass="edline"></asp:TextBox><asp:DropDownList ID="ddlQqchB" runat="server" Width="80">
                                        <asp:ListItem Value="1">天</asp:ListItem>
                                        <asp:ListItem Value="2">工作天内</asp:ListItem>
                                    </asp:DropDownList>
                                    支付策划费<asp:TextBox ID="txtQqchB2" runat="server"  Width="40"  CssClass="edline"></asp:TextBox>元。
                              </p>
                              <p style="text-align:left; padding:0px;margin:0px;">
                                    C.提交策划报告修改稿<asp:TextBox ID="txtQqchC1" runat="server"  Width="40"  CssClass="edline"></asp:TextBox><asp:DropDownList ID="ddlQqchC" runat="server" Width="80">
                                        <asp:ListItem Value="1">天</asp:ListItem>
                                        <asp:ListItem Value="2">工作天内</asp:ListItem>
                                    </asp:DropDownList>
                                    支付策划费<asp:TextBox ID="txtQqchC2" runat="server"  Width="40"  CssClass="edline"></asp:TextBox>元。
                              </p>
                              <p style="text-align:left; padding:0px;margin:0px;">
                                    D.提交策划报告终稿<asp:TextBox ID="txtQqchD1" runat="server"  Width="40"  CssClass="edline"></asp:TextBox><asp:DropDownList ID="ddlQqchD" runat="server" Width="80">
                                        <asp:ListItem Value="1">天</asp:ListItem>
                                        <asp:ListItem Value="2">工作天内</asp:ListItem>
                                    </asp:DropDownList>
                                    支付策划费<asp:TextBox ID="txtQqchD2" runat="server"  Width="40"  CssClass="edline"></asp:TextBox>元。
                              </p>
                               <p style="text-align:left; padding:0px;margin:0px;">
                                    E.发展商确认终稿<asp:TextBox ID="txtQqchE1" runat="server"  Width="40"  CssClass="edline"></asp:TextBox><asp:DropDownList ID="ddlQqchE" runat="server" Width="80">
                                        <asp:ListItem Value="1">天</asp:ListItem>
                                        <asp:ListItem Value="2">工作天内</asp:ListItem>
                                    </asp:DropDownList>
                                    支付策划费<asp:TextBox ID="txtQqchE2" runat="server"  Width="40"  CssClass="edline"></asp:TextBox>元。
                              </p>
                          </div>
                     </div>
                     
                     <div  style="position: relative;left: 20px;width: 150px;font-family: Arial;text-align: left;">
                        <div ><p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                            二.月费支付方式：</span></p></div>
                     </div>
                     <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                          <div >
                               <p style="text-align:left; padding:0px;margin:0px;">
                                    <asp:DropDownList ID="ddlQqch2" runat="server" Width="120" >
                                        <asp:ListItem Value="1">每月___日</asp:ListItem>
                                        <asp:ListItem Value="2">最后一天</asp:ListItem>
                                        <asp:ListItem Value="3">最后一个工作日</asp:ListItem>
                                    </asp:DropDownList>
                                    前支付<asp:TextBox ID="txtQqch22" runat="server" Width="40" CssClass="edline"></asp:TextBox>元。
                                   <asp:HiddenField ID="txtQqch21"
                                       runat="server" />
                               </p>
                          </div>
                     </div>
                     
                     
                     <div  style="position: relative;left: 20px;width: 150px;font-family: Arial;text-align: left;">
                        <div ><p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                            三.一次性支付：</span></p></div>
                     </div>
                     <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                          <div >
                               <p style="text-align:left; padding:0px;margin:0px;">
                                   代理合同签署 <asp:TextBox runat="server" id="txtQqch31" Width="40" CssClass="edline"> </asp:TextBox>
                                    <asp:DropDownList ID="ddlQqch3" runat="server" Width="80">
                                        <asp:ListItem Value="1">天</asp:ListItem>
                                        <asp:ListItem Value="2">工作天内</asp:ListItem>
                                    </asp:DropDownList>
                                    支付策划费<asp:TextBox ID="txtQqch32" runat="server" Width="40" CssClass="edline"></asp:TextBox>元。
                               </p>
                          </div>
                     </div>
                 </div>
                 
                 
                 <div id="pg3" class="page" style="display:none;">
                      <div  style="position: relative;left: 20px;width: 160px;font-family: Arial;text-align: left;">
                        <div ><p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                            一.手正常独立成交，条款：</span></p></div>
                     </div>
                      <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                         <table>
                            <tr>
                                <td>
                                  <asp:RadioButtonList ID="radlSalseAgency" runat="server"  RepeatDirection="Horizontal">
                                   </asp:RadioButtonList>
                                </td>
                                <td> <input id="Button1" type="button" value="增加" onclick="AddInputArea_SalseAgency()" /> 
                                    <asp:HiddenField ID="hfldSalseAgency" runat="server" />
                               </td>
                            </tr>
                         </table>
                         <div id="SalseAgencyArea"></div> 
                     </div>
                     <div  style="position: relative;left: 20px;width: 150px;font-family: Arial;text-align: left;">
                        <div ><p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                            二.发展商客，条款：</span></p></div>
                     </div>
                      <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                          <div >
                               <p style="text-align:left; padding:0px;margin:0px;">
                                   <table>
                                    <tr>
                                    <td>A.限度（单选）：</td>
                                    <td><asp:RadioButtonList ID="radlXsdl" runat="server" 
                                          RepeatDirection="Horizontal">
                                   </asp:RadioButtonList></td>
                                        <asp:HiddenField ID="hfldXsdlA2" runat="server" /> <asp:HiddenField ID="hfldXsdlA3" runat="server" />
                                    </tr>
                                    </table>
                               </p>
                               <p style="text-align:left; padding:0px;margin:0px;">
                                      B.
                                      <asp:DropDownList ID="ddlXsdl" runat="server">
                                      </asp:DropDownList>
                                   <asp:HiddenField ID="hfldXsdlB2" runat="server" />
                               </p>
                          </div>
                     </div>
                 </div>
                 <div id="pg4" class="page" style="display:none;">
                     <div  style="position: relative;left: 20px;width: 160px;font-family: Arial;text-align: left;">
                        <div ><p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                            一.中原成交，条款：</span></p></div>
                     </div>
                      <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                          <table>
                            <tr>
                                <td>
                                    <asp:RadioButtonList ID="radlLease" runat="server" RepeatDirection="Horizontal">
                                    </asp:RadioButtonList>
                                </td>
                                <td>
                                    <input id="Button3" type="button" value="增加" onclick="AddInputArea_Lease()" />
                                    <asp:HiddenField ID="hfldLease" runat="server" />
                                </td>
                            </tr>
                          </table>
                          <div id="LeaseArea">
                          </div>
                     </div>
                     <div  style="position: relative;left: 20px;width: 150px;font-family: Arial;text-align: left;">
                        <div ><p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                            二.发展商客，条款：</span></p></div>
                     </div>
                      <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                          <div >
                               <p style="text-align:left; padding:0px;margin:0px;">
                                    <table>
                                    <tr>
                                    <td>A.限度（单选）：</td>
                                    <td>
                                        <asp:RadioButtonList ID="radlZz" runat="server" RepeatDirection="Horizontal">
                                        </asp:RadioButtonList>
                                        <asp:HiddenField ID="hfldZzA2" runat="server" /><asp:HiddenField ID="hfldZzA3" runat="server" />
                                   </td>
                                    </tr>
                                    </table>
                               </p>
                               <p style="text-align:left; padding:0px;margin:0px;">
                                      B.
                                       <asp:DropDownList ID="ddlZz" runat="server">
                                      </asp:DropDownList>
                                   <asp:HiddenField ID="hfldZzB2" runat="server" />
                               </p>
                          </div>
                     </div>
                 </div>
                 
                 
                  <div id="pg5" class="page" style="display:none;">
                     <div  style="position: relative;left: 20px;width: 160px;font-family: Arial;text-align: left;">
                        <div ><p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                            一.联动成交，佣金条款：</span></p></div>
                     </div>
                      <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                          <table>
                            <tr>
                                <td>
                                    <asp:RadioButtonList ID="radlUnionComm" runat="server" RepeatDirection="Horizontal">
                                    </asp:RadioButtonList>
                                </td>
                                <td>
                                    <input id="Button4" type="button" value="增加" onclick="AddInputArea_UnionComm()" />
                                    <asp:HiddenField ID="hfldUnionComm" runat="server" />
                                </td>
                            </tr>
                          </table>
                          <div id="UnionCommArea">
                          </div>
                     </div>
                     
                     <div  style="position: relative;left: 20px;width: 200px;font-family: Arial;text-align: left;">
                        <div ><p style="text-align:left;"><span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                            二.联动成交，发展商额外奖金：</span></p></div>
                     </div>
                      <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;top:-20px;">
                          <table>
                            <tr>
                                <td>
                                    <asp:RadioButtonList ID="radlUnionDeveloper" runat="server" RepeatDirection="Horizontal">
                                    </asp:RadioButtonList>
                                </td>
                                <td>
                                    <input id="Button5" type="button" value="增加" onclick="AddInputArea_UnionDeveloper()" />
                                    <asp:HiddenField ID="hfldUnionDeveloper" runat="server" />
                                </td>
                            </tr>
                          </table>
                          <div id="UnionDeveloperArea">
                          </div>
                     </div>
                  </div>
                  
                 </td>
            </tr>
            <tr>
                <td valign="top"><span class="detailTitle">现报数点数：</span></td>
                <td align="left" colspan="3">
                    <div id="Div1" class="page" style="margin:0px;">
                         <div style="position: relative;left:20px;width: 507px;font-family: Arial;text-align: left;">
                        <p style="text-align:left; padding:0px;margin:0px;">
                            1.先选产品类型，按成交金额的<asp:TextBox ID="txtPoint1" runat="server" CssClass="edline" Width="40"></asp:TextBox>%计提;
                        </p>
                        <p style="text-align:left; padding:0px;margin:0px;">
                            2.<asp:DropDownList ID="ddlPoint" runat="server">
                                <asp:ListItem Value="1">按租金</asp:ListItem>
                                <asp:ListItem Value="2">月均租金的____倍计提</asp:ListItem>
                            </asp:DropDownList>
                            <asp:HiddenField ID="hfdlPoint" runat="server" />
                        </p>
                        <p style="text-align:left; padding:0px;margin:0px;">
                            3.先选产品类型，按成交金额的<asp:TextBox ID="txtPoint31" runat="server" CssClass="edline" Width="40"></asp:TextBox>%计提，每套现金额奖励<asp:TextBox ID="txtPoint32" runat="server" CssClass="edline" Width="40"></asp:TextBox>元。
                        </p>
                        </div>
                    </div>
                </td>
            </tr> 
            
            <tr>
                <td><span class="detailTitle">结算周期：</span></td>
                <td align="left" colspan="3">
                    <asp:RadioButtonList ID="radlAccountCycle" runat="server" 
                        RepeatDirection="Horizontal">
                    </asp:RadioButtonList>
                    <asp:HiddenField ID="hfldAccountCycle" runat="server" />
                </td>
            </tr>
            
            <tr>
                <td valign="top"><span class="detailTitle">结算条件：</span></td>
                <td align="left" colspan="3">
                    <div id="Div2" class="page" style="">
                             <div style="position: relative;left: 20px;font-family: Arial;text-align: left;">
                                 <p style="text-align:left; padding:0px;margin:0px;">
                                    <asp:CheckBoxList ID="chklAccountCondition" RepeatDirection="Horizontal" RepeatColumns="4"  style="line-height:10px;" runat="server" >
                                    </asp:CheckBoxList>
                                     <asp:HiddenField ID="hfldAccountCondition" runat="server" />
                                 </p>
                                 <p style="text-align:left; padding:0px;margin:0px;">
                                    <span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                                     一.以买家付款进度作为结算条件：</span>
                                 </p>
                                 <p style="text-align:left; padding:0px;margin:0px;line-height:0px;">
                                    <asp:CheckBoxList ID="chklBidderAccountCondition" runat="server" 
                                         RepeatDirection="Horizontal" RepeatColumns="3" style="line-height:10px;">
                                    </asp:CheckBoxList>
                                 </p>
                                  <p style="text-align:left; padding:0px;margin:0px;">
                                    <span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                                      二.以完成销售目标作为结算条件：</span>
                                 </p>
                                 <p style="text-align:left; padding:0px;margin:0px;">
                                     <asp:RadioButtonList ID="radlSalseAccountCondition" RepeatDirection="Horizontal"  RepeatColumns="4" runat="server" style="line-height:10px;">
                                     </asp:RadioButtonList>
                                     <asp:HiddenField ID="hfldSalseAccountCondition" runat="server" />
                                 </p>
                             </div>
                                                          
                    </div>
                </td>
                
            </tr>
            
            
             <tr>
                <td valign="top"><span class="detailTitle">收佣条件：</span></td>
                <td align="left" colspan="3">
                    <div id="Div3" class="page" style="">
                         <div style="position: relative;left: 20px;width: 507px;font-family: Arial;text-align: left;">
                             <p style="text-align:left; padding:0px;margin:0px;">
                                    以结算条件作为选项的<input name="Commission1" id="Commission1" type="text"  style="width:40px;"  /><select name="Commission2" id="Commission2"><option value="0">天</option><option value="1">工作天</option></select>内,支付<input name="Commission3" id="Commission3" style="width:40px;" type="text" />%；
                             <input id="Button2" type="button" value="增加" onclick="AddCommission()" />
                                  <div id="CommissionArea">
                                        
                                  </div>
                                  <asp:HiddenField ID="hfldCommission" runat="server"  /> 
                             </p>
                         </div>
                    </div>
                </td>
            </tr>
            
            <tr>
                <td valign="top"><span class="detailTitle">拆街：</span></td>
                <td align="left" colspan="3">
                     <div id="Div4" class="page" style="">
                         <div style="position: relative;left: 20px;width: 600px;font-family: Arial;text-align: left;">
                             <p style="text-align:left; padding:0px;margin:0px;">
                                 <span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                                 一.对外分佣：</span>
                             </p>
                             <p style="text-align:left; padding:0px;margin:0px;">
                                 <asp:RadioButtonList ID="radlOutComm" runat="server" RepeatDirection="Horizontal">
                                 </asp:RadioButtonList>
                                 <asp:HiddenField ID="hfldOutComm1" runat="server" />
                             </p>
                              <p style="text-align:left; padding:0px;margin:0px;">
                                 <span style="font-family:Arial;font-size:13px;font-weight:normal;font-style:normal;text-decoration:none;color:#333333;">
                                  二.转介盘源转介费：</span>
                             </p>
                             <p style="text-align:left; padding:0px;margin:0px;">
                                 <asp:RadioButtonList ID="radlReferral" runat="server" RepeatDirection="Horizontal">
                                 </asp:RadioButtonList>
                                 <asp:HiddenField ID="hfldReferral1" runat="server" />
                             </p>
                         </div>
                     </div>
                </td>
            </tr>
            
             <tr>
                <td valign="top"><span class="detailTitle">项目附件：</span></td>
                <td align="left" colspan="3">
                    <table class="page" style="width: 100%;">
                                                <tr>
                                                    <td>
                                                        附件类型：
                                                    </td>
                                                    <td colspan="3" align="left">
                                                        <asp:DropDownList ID="ddlFileType" runat="server">
                                                        </asp:DropDownList>
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td align="left" style="font-size: 15px;">
                                                        上传文件:
                                                    </td>
                                                    <td align="left" colspan="3">
                                                        <font face="宋体">
                                                            <input id="txtFilePath" runat="server" name="UploadFile" style="font-size: 9pt; width: 388px"
                                                                type="file" />
                                                        </font>
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td align="left" style="font-size: 15px;">
                                                        其他资料:
                                                    </td>
                                                    <td align="left" colspan="3">
                                                        <font face="宋体">
                                                            <asp:TextBox ID="txtProjectDesc" runat="server" Width="384px"></asp:TextBox></font>
                                                        <asp:Button ID="btnUpLoad" Style="background-image: url(../images/pic15.gif); border-color: #ffffff; background-repeat: no-repeat; padding-left: 17px;" CausesValidation="false" runat="server" Visible="false"
                                                            Text="上传" OnClick="btnUpLoad_Click" />
                                                        <asp:HiddenField ID="HiddenField2" runat="server" />
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td colspan="4">
                                               <table id="tempTable" style="display: none; border-width: 0px; border-style: dotted;
                                                width: 600px; background-color: rgb(192, 255, 192);" border="0" rules="all" cellspacing="1"
                                                cellpadding="1">
                                                <tr style="background-color: rgb(216, 200, 168);" class="ttTable" align="center">
                                                    <td>
                                                        上传资料名称
                                                    </td>
                                                    <td style="width: 40px;">
                                                        删除
                                                    </td>
                                                </tr>
                                            </table>
                                            <asp:DataGrid ID="dgList" Visible="false" runat="server" AutoGenerateColumns="False"
                                                BackColor="#C0FFC0" BorderStyle="Dotted" BorderWidth="0px" CellPadding="1" CellSpacing="1"
                                                DataKeyField="Project_Report_ID" PageSize="20" Width="600px" OnItemCommand="dgList_ItemCommand"
                                                OnItemDataBound="dgList_ItemDataBound">
                                                <PagerStyle Mode="NumericPages" Position="TopAndBottom" />
                                                <AlternatingItemStyle BackColor="#F0F0E8" CssClass="td" />
                                                <ItemStyle BackColor="#F8F4E4" CssClass="td" />
                                                <HeaderStyle BackColor="#D8C8A8" CssClass="ttTable" HorizontalAlign="Center" />
                                                <Columns>
                                                    <asp:HyperLinkColumn DataNavigateUrlField="Project_Report_FilePath" DataTextField="Report_File_Name"
                                                        HeaderText="上传资料名称" Target="_blank"></asp:HyperLinkColumn>
                                                    <asp:TemplateColumn HeaderText="删除">
                                                        <ItemStyle Font-Bold="False" Font-Italic="False" Font-Overline="False" Font-Strikeout="False"
                                                            Font-Underline="False" HorizontalAlign="Center" Wrap="False" />
                                                        <ItemTemplate>
                                                            <asp:ImageButton ID="imgbtnDelete" runat="server" AlternateText="删除" BorderStyle="Dotted"
                                                                BorderWidth="0px" CommandName="Delete" ImageAlign="Middle" ImageUrl="../images/delete.gif" />
                                                        </ItemTemplate>
                                                        <HeaderStyle Width="40px" />
                                                    </asp:TemplateColumn>
                                                </Columns>
                                            </asp:DataGrid>
                                                    </td>
                                                </tr>
                                            </table>
                                           
                </td>
            </tr>
             <tr>
                <td>&nbsp;</td>
                <td colspan="3" align="left">
                <span class="detailTitle">营销总监：</span>
                <asp:TextBox ID="txtMarketing1" runat="server"  CssClass="edline" Width="60"></asp:TextBox>&nbsp;<asp:ImageButton ID="ibtnMarketing1" runat="server" ImageUrl="../images/vie.gif" />
                    &nbsp;&nbsp;&nbsp;<asp:HiddenField ID="hfldMarketing1" runat="server" />
&nbsp;<span class="detailTitle">营销副总监：</span>
                <asp:TextBox ID="txtMarketing2" runat="server"  CssClass="edline" Width="60"></asp:TextBox>&nbsp;<asp:ImageButton ID="ibtnMarketing2" runat="server" ImageUrl="../images/vie.gif" />
                <asp:HiddenField ID="hfldMarketing2" runat="server" />
                    &nbsp;&nbsp;&nbsp;
                 <span class="detailTitle">项目经理：</span>
                <asp:TextBox ID="txtManager" runat="server"  CssClass="edline" Width="60"></asp:TextBox>&nbsp;<asp:ImageButton ID="ibtnManager" runat="server" ImageUrl="../images/vie.gif" />
                 <asp:HiddenField ID="hfldManager" runat="server" />
                    &nbsp;&nbsp;&nbsp;
                </td>
            </tr>
            <tr>
                <td>&nbsp;</td>
                <td colspan="3" align="left">
                <span class="detailTitle">事总：</span>
                <asp:TextBox ID="txtBusiness" runat="server"  CssClass="edline" Width="60"></asp:TextBox>&nbsp;<asp:ImageButton ID="ibtnBusiness" runat="server" ImageUrl="../images/vie.gif" />
                 <asp:HiddenField ID="hfldBusiness" runat="server" />
                    &nbsp;&nbsp;&nbsp;
                      <span class="detailTitle">部门负责人：</span>
                <asp:TextBox ID="txtDepartmentHead" runat="server"  CssClass="edline" Width="60"></asp:TextBox>&nbsp;<asp:ImageButton ID="ibtnDepartmentHead" runat="server" ImageUrl="../images/vie.gif" />
                 <asp:HiddenField ID="hfldDepartmentHead" runat="server" />
                    &nbsp;&nbsp;&nbsp;
                </td>
             </tr>   
            <tr>
                <td  colspan="4">
                 <center>
                    <asp:Button ID="btnSubmit" runat="server" Text="保存"  OnClientClick="return DataCheck();"
                         onclick="btnSubmit_Click"  /> &nbsp;&nbsp;&nbsp;<input type="reset" runat="server" id="btnReset" value="重置" /> &nbsp;&nbsp;&nbsp;
                     <asp:Button ID="btnDelete" runat="server" OnClientClick="return confirm('是否确定删除？')" onclick="btnDelete_Click" Text="删除" 
                         Visible="False" />
                         &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                     <asp:Button ID="btnAudit" runat="server"   Text="营销[副]总监审核" OnClientClick="return confirm('是否确定审核通过？')" onclick="btnAudit_Click" />

                         
                   </center>
                </td>
            
            </tr>
            
              
         </table>
         </center>

        </td>
    
      </tr>
      <tr>
        <td height="40" colspan="4"><table width="100%" height="1" border="0" cellpadding="0" cellspacing="0" bgcolor="#CCCCCC">
          <tr>
            <td></td>
          </tr>
        </table></td>
      </tr>
      <tr>
        <td width="2%">&nbsp;</td>
        <td width="51%" class="left_txt"><img src="../images/icon-mail2.gif" width="16" height="11"> 
            客户服务邮箱：servers@centaline.com<br>
              <img src="..../images/icon-phone.gif" width="17" height="14"> 
            官方网站：http://www.centaline.com.cn/</td>
        <td>&nbsp;</td>
        <td>&nbsp;</td>
      </tr>
    </table></td>
    <td background="../images/mail_rightbg.gif">&nbsp;</td>
  </tr>
  <tr>
    <td valign="bottom" background="..../images/mail_leftbg.gif"><img src="../images/buttom_left2.gif" width="17" height="17" /></td>
    <td background="../images/buttom_bgs.gif"><img src="../images/buttom_bgs.gif" width="17" height="17"></td>
    <td valign="bottom" background="../images/mail_rightbg.gif"><img src="../images/buttom_right2.gif" width="16" height="17" /></td>
  </tr>
</table>
</form>
</body>
</html>
    <script type="text/javascript" language="javascript">
        function ddlQgch() {
            if (document.all.ddlQqch2.selectedIndex == 0) {
                var a = window.prompt("请输入天数", "默认值");
                document.getElementById("txtQqch21").value = a;
                document.all.ddlQqch2.options[document.all.ddlQqch2.selectedIndex].text = "每月" + a + "日";
            } else if (document.all.ddlXsdl.selectedIndex == 0) {
                var a = window.prompt("请输入多少%", "0");
                document.getElementById("hfldXsdlB2").value = a;
                document.all.ddlXsdl.options[document.all.ddlXsdl.selectedIndex].text = "按成交金额的" + a + "%计提";
            } else if (document.all.ddlXsdl.selectedIndex == 1) {
                var a = window.prompt("请输入多少元", "0");
                document.getElementById("hfldXsdlB2").value = a;
                document.all.ddlXsdl.options[document.all.ddlXsdl.selectedIndex].text = "每套按" + a + "元收取手续费";
            } else if (document.all.ddlPoint.selectedIndex == 1) {
                var a = window.prompt("请输入多少倍", "0");
                document.getElementById("hfdlPoint").value = a;
                document.all.ddlPoint.options[document.all.ddlPoint.selectedIndex].text = "月均租金的" + a + "倍计提";
            }
        }

        function ddlSingType() {

            if (document.all.ddlSignType.selectedIndex == 1) {

                nonePageLink();
                document.getElementById("lk5").style.display = "inline-block";
                document.getElementById("pg5").style.display = "block";
                document.getElementById("lk5").className = "asel";

                document.getElementById("chklAgencyType_3").setAttribute("disabled", "disabled");
                document.getElementById("chklAgencyType_3").checked = true;
            }
            else {
                document.getElementById("lk5").style.display = "none";
                document.getElementById("pg5").style.display = "none";
                document.getElementById("lk5").className = "aa";

                document.getElementById("lk1").style.display = "inline-block";
                document.getElementById("lk1").className = "asel";
                document.getElementById("pg1").style.display = "block";
                document.getElementById("chklAgencyType_3").removeAttribute("disabled");
                document.getElementById("chklAgencyType_3").checked = false;
            }
        }

        function getElementsByClassName(className) {
            var all = document.all ? document.all : document.getElementsByTagName('*');
            var elements = new Array();
            for (var e = 0; e < all.length; e++) {
                if (all[e].className == className) {
                    elements[e] = all[e];
                }
            }
            return elements;
        }

        function nonePageLink() {
            var daili = document.getElementById("daili");
            var dailiItem = daili.getElementsByTagName("span");
            for (i = 0; i < dailiItem.length; i++) {
                dailiItem[i].className = "aa";
                document.getElementById("pg" + (i + 1)).style.display = "none";
            }

        }

        function chklAgencyType(obje) {

            var a = obje.id;
            if (a == "chklAgencyType_0") {
                if (document.getElementById("chklAgencyType_0").checked) {
                    nonePageLink();
                    document.getElementById("lk2").style.display = "inline-block";
                    document.getElementById("lk2").className = "asel";
                    document.getElementById("pg2").style.display = "block";
                } else {
                    document.getElementById("lk2").style.display = "none";
                    document.getElementById("lk2").className = "aa";
                    document.getElementById("pg2").style.display = "none";
                    document.getElementById("lk1").style.display = "inline-block";
                    document.getElementById("lk1").className = "asel";
                    document.getElementById("pg1").style.display = "block";
                }
            } else if (a == "chklAgencyType_1") {
                if (document.getElementById("chklAgencyType_1").checked) {
                    nonePageLink();
                    document.getElementById("lk3").style.display = "inline-block";
                    document.getElementById("lk3").className = "asel";
                    document.getElementById("pg3").style.display = "block";
                }
                else {
                    document.getElementById("lk3").style.display = "none";
                    document.getElementById("lk3").className = "aa";
                    document.getElementById("pg3").style.display = "none";
                    document.getElementById("lk1").style.display = "inline-block";
                    document.getElementById("lk1").className = "asel";
                    document.getElementById("pg1").style.display = "block";
                }
            } else if (a == "chklAgencyType_2") {
                if (document.getElementById("chklAgencyType_2").checked) {
                    nonePageLink();
                    document.getElementById("lk4").style.display = "inline-block";
                    document.getElementById("lk4").className = "asel";
                    document.getElementById("pg4").style.display = "block";
                } else {
                    document.getElementById("lk4").style.display = "none";
                    document.getElementById("lk4").className = "aa";
                    document.getElementById("pg4").style.display = "none";
                    document.getElementById("lk1").style.display = "inline-block";
                    document.getElementById("lk1").className = "asel";
                    document.getElementById("pg1").style.display = "block";
                }
            }
            else if (a == "chklAgencyType_3") {
                if (document.getElementById("chklAgencyType_3").checked) {
                    nonePageLink();
                    document.getElementById("lk5").style.display = "inline-block";
                    document.getElementById("lk5").className = "asel";
                    document.getElementById("pg5").style.display = "block";
                }
                else {
                    document.getElementById("lk5").style.display = "none";
                    document.getElementById("lk5").className = "aa";
                    document.getElementById("pg5").style.display = "none";
                    document.getElementById("lk1").style.display = "inline-block";
                    document.getElementById("lk1").className = "asel";
                    document.getElementById("pg1").style.display = "block";
                }
            } else if (a == "chklXsdl_3") {
                var a = window.prompt("请输入多少%", "0");
                document.getElementById("hfldXsdl").value = a;
                writeLabel("chklXsdl_3", "货量占比，按成交金额的" + a + "%计提");
            } else if (a == "radlXsdl_0") {
                var a = window.prompt("请输入多少套", "0");
                document.getElementById("hfldXsdlA2").value = a;
                writeLabel("radlXsdl_0", a + "套以内");
            } else if (a == "radlXsdl_1") {
                var a = window.prompt("请输入多少套", "0");
                var b = window.prompt("请输入多少%", "0");
                document.getElementById("hfldXsdlA2").value = a;
                document.getElementById("hfldXsdlA3").value = b;
                writeLabel("radlXsdl_1", "可售货量" + a + "套的" + b + "%以内");
            } else if (a == "radlZz_0") {
                var a = window.prompt("请输入多少套", "0");
                document.getElementById("hfldZzA2").value = a;
                writeLabel("radlZz_0", a + "套以内");
            } else if (a == "radlZz_1") {
                var a = window.prompt("请输入多少套", "0");
                var b = window.prompt("请输入多少%", "0");
                document.getElementById("hfldZzA2").value = a;
                document.getElementById("hfldZzA3").value = b;
                writeLabel("radlZz_1", "可售货量" + a + "套的" + b + "%以内");
            } else if (a == "chklAccountCondition_5") {
                var a = window.prompt("请输入多少日", "0");
                document.getElementById("hfldAccountCondition").value = a;
                writeLabel("chklAccountCondition_5", "每月" + a + " 日前");
            } else if (a == "radlOutComm_0") {
                var a = window.prompt("请输入多少元", "0");
                document.getElementById("hfldOutComm1").value = a;
                writeLabel("radlOutComm_0", "一次性支付" + a + " 元");
            } else if (a == "radlOutComm_1") {
                var a = window.prompt("请输入佣金多少%", "0");
                document.getElementById("hfldOutComm1").value = a;
                writeLabel("radlOutComm_1", "按中原实收佣金" + a + " %计提（含税）");
            } else if (a == "radlOutComm_2") {
                var a = window.prompt("请输入佣金多少%", "0");
                document.getElementById("hfldOutComm1").value = a;
                writeLabel("radlOutComm_2", "按中原成交金额" + a + " %计提（含税）");
            } else if (a == "radlReferral_0") {
                var a = window.prompt("请输入多少元", "0");
                document.getElementById("hfldReferral1").value = a;
                writeLabel("radlReferral_0", "一次性支付" + a + " 元");
            } else if (a == "radlReferral_1") {
                var a = window.prompt("请输入佣金多少%", "0");
                document.getElementById("hfldReferral1").value = a;
                writeLabel("radlReferral_1", "按中原实收佣金" + a + " %计提（含税）");
            } else if (a == "radlReferral_2") {
                var a = window.prompt("请输入佣金多少%", "0");
                document.getElementById("hfldReferral1").value = a;
                writeLabel("radlReferral_2", "按中原成交金额" + a + " %计提（含税）");
            } else if (a == "chklEncourage_3") {
                var a = window.prompt("请输入金额多少%", "0");
                document.getElementById("hfdlEncourage").value = a;
                writeLabel("chklEncourage_3", "货量占比，按成交金额的" + a + " %计提");
            } else if (a == "radlAccountCycle_2") {
                var a = window.prompt("请输入多少日", "0");
                document.getElementById("hfldAccountCycle").value = a;
                writeLabel("radlAccountCycle_2", "每月" + a + " 日");
            } else if (a == "radlSalseAccountCondition_0") {
                var a = window.prompt("请输入销售目标是什么", "");
                document.getElementById("hfldSalseAccountCondition").value = a;
                writeLabel("radlSalseAccountCondition_0", "达到首个销售目标（" + a + "）");
            } else if (a == "radlSalseAccountCondition_1") {
                var a = window.prompt("请输入销售目标是什么", "");
                document.getElementById("hfldSalseAccountCondition").value = a;
                writeLabel("radlSalseAccountCondition_1", "达到第二个销售目标（" + a + "）");
            } else if (a == "radlSalseAccountCondition_2") {
                var a = window.prompt("请输入销售目标是什么", "");
                document.getElementById("hfldSalseAccountCondition").value = a;
                writeLabel("radlSalseAccountCondition_2", "达到第三个销售目标（" + a + "）");
            } else if (a == "radlSalseAccountCondition_3") {
                var a = window.prompt("请输入销售目标是什么", "");
                document.getElementById("hfldSalseAccountCondition").value = a;
                writeLabel("radlSalseAccountCondition_3", "达到第四个销售目标（" + a + "）");
            } else if (a == "radlSalseAccountCondition_4") {
                var a = window.prompt("请输入销售目标是什么", "");
                document.getElementById("hfldSalseAccountCondition").value = a;
                writeLabel("radlSalseAccountCondition_4", "达到第五个销售目标（" + a + "）");
            } else if (a == "radlSalseAccountCondition_5") {
                var a = window.prompt("请输入销售目标是什么", "");
                document.getElementById("hfldSalseAccountCondition").value = a;
                writeLabel("radlSalseAccountCondition_5", "完成年度销售目标（" + a + "）");
            } 

        }


        function writeLabel(obje1, obje2) {
            var a = obje1;
            var b = obje2;
            //获取所有lable标签
            var arr = document.getElementsByTagName("label");
            //for循环
            for (i = 0; i < arr.length; i++) {
                //取出参数for的值
                var forvalue = arr[i].getAttributeNode("for").value;
                //因为for的值和相应checkbox的id对应，所以判断是否相等，如果
                //相等，那么它的innerHTML的值就是label的显示的值
                if (forvalue == a) {
                    //或者使用innerText来获取。
                    arr[i].innerHTML = b;
                    //alert("复选框的label for标签的值为：" + arr[i].innerHTML);
                }
            }
        }

        document.getElementById("txtUserInput").style.width = "190px";
 
    </script>